Skip to content

[pull] canary from vercel:canary#1054

Merged
pull[bot] merged 3 commits into
code:canaryfrom
vercel:canary
May 18, 2026
Merged

[pull] canary from vercel:canary#1054
pull[bot] merged 3 commits into
code:canaryfrom
vercel:canary

Conversation

@pull
Copy link
Copy Markdown

@pull pull Bot commented May 18, 2026

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.4)

Can you help keep this open source service alive? 💖 Please sponsor : )

mischnic and others added 3 commits May 18, 2026 13:35
Adapters implementing `modifyConfig` may need to know the absolute
project directory to perform path resolution or apply directory-specific
configuration logic. Without this value, adapters had no reliable way to
determine where the application lives on disk.

onBuildComplete already received the directory as a parameter.
### What?

When instant validation flags a route that can't load instantly, the
overlay shows a warning. This PR (1) distinguishes nav-phase warnings
from initial-render ones in the overlay text, and (2) clears the
nav-phase warnings on route change so they don't accumulate after the
user has moved on.

### Why?

The redbox previously couldn't tell whether a route's instant warning
was raised while rendering it directly or while navigating into it — the
text and stack looked the same. And once one was surfaced, it stuck
around even after the user navigated elsewhere, where it was no longer
actionable. The two changes together make each warning describe the
phase that produced it and only stay visible while it's still relevant.

### Demo

- Subnav under Suspense:
[cookies](https://error-messages-overhaul-ibsl.labs.vercel.dev/scenario/41-subnav-cookies)
·
[fetch](https://error-messages-overhaul-ibsl.labs.vercel.dev/scenario/42-subnav-fetch)

### How

- New in-navigation variants of the body factory messages ("during the
initial render or a navigation") let the overlay tell nav warnings apart
from initial-render ones. The diagnostic clause stays aligned ("accessed
outside of \`<Suspense>\`"); only the phase and consequence change.
- The overlay reads the phase off the message, picks a matching
headline, and on route change drops nav warnings while keeping
initial-render errors in the redbox stack.
- Renames the \`GuidanceVariant\` value (\`'navigation' → 'dynamic'\`)
that collided with the new in-nav phase concept.

---------

Co-authored-by: Cursor <cursoragent@cursor.com>
Move next.config evaluation inside the try catch where we import and
transform it

This ensures we print an appropriate help link if the export function
throws
@pull pull Bot locked and limited conversation to collaborators May 18, 2026
@pull pull Bot added the ⤵️ pull label May 18, 2026
@pull pull Bot merged commit 0114ea2 into code:canary May 18, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants